$(function() {
	var availableTags = [
	    "Acer",
	    "Apple",
	    "Asus",
	    "Canon",
	    "Desire",
	    "Galaxy",
	    "HTC",
	    "Lumia",
	    "Motorola",
	    "Nikon",
	    "Nokia",
	    "One",
	    "Razr",
	    "Samsung",
	    "Sensation",
	    "Sony",
	    "Xperia"
	];
	$( "#keyword" ).autocomplete({
	    source: availableTags
	});
	
	$( "#radioset" ).buttonset();
	
	$( "#dialog" ).dialog({
	    autoOpen: false,
	    //show: "blind",
	    //hide: "explode",
	    width: 400,
	    buttons: [
	        {
	            text: "Ok",
	            click: function() {
	            	changeLink();
	                $( this ).dialog( "close" );
	            }
	        },
	        {
	            text: "Cancel",
	            click: function() {
	                $( this ).dialog( "close" );
	            }
	        }
	    ]
	});
	// Link to open the dialog
	$( "#dialog-link" ).click(function( event ) {
	    $( "#dialog" ).dialog( "open" );
	    event.preventDefault();
	});
	
	$("#searchicon, #dialog-link, .actionButt, .submitButt, .resetButt")
			.button();
	
    $( "#datepicker" ).datepicker();
    
    //ADVANCED
	$("#password").passStrength({
		shortPass:"top_shortPass",
		badPass:"top_badPass",
		goodPass:"top_goodPass",
		strongPass:"top_strongPass",
		baseStyle:"top_testresult",
		userid:"#user_id_adv",
		messageloc:0
	});
    
});